QuickTime 3 Reference

| Previous | Chapter Contents | Chapter Top | Next |

Structure of an Effect Description

An effect description is a QTAtomContainer data structure, the general QuickTime structure for holding a set of QTAtoms . All effect descriptions must contain the set of required atoms, which specify attributes such as which effect component will be used. In addition, effect descriptions can contain a variable number of parameter atoms , which hold the values of the parameters of the effect.

Each atom contains either data or a set of child atoms. If a parameter atom contains data, the data is the value of the parameter, and this value remains constant while the effect executes. If a parameter atom contains a set of child atoms, they typically contain a tween entry so the value of the parameter will be interpolated for the duration of the effect.

You assemble an effect description by adding the appropriate set of atoms to a QTAtomContainer data structure.

You can find out what the appropriate atoms are by making an ImageCodecGetParameterList call to the effect component. This will fill an atom container with a set of parameter description atoms . These atoms contain descriptions of the effect parameters, such as each parameter's atom type, data range, default value, and so on. The default value in each description atom is itself a QTAtom that can be inserted directly into your effect description.

You can modify the data in the parameter atoms directly, or let the user set them by calling QTCreateStandardParameterDialog , which will return a complete effect description (you will need to add kEffectSourceName atoms for effects that require one or two sources).

You then add the effect description to the media of the video track that contains the effect. The effect description forms the sample for the media of the video track.

For detailed information about creating and editing QTAtom and QTAtomContainer data structures, see Chapter 1, "Movie Toolbox." For more information about tweens, see Chapter 25, "Tween Components and Native Tween Types."


© 1998 Apple Computer, Inc.

| Previous | Chapter Contents | Chapter Top | Next |